//
//  CheckTextField.m
//  PetAPP
//
//  Created by apple on 16/3/4.
//  Copyright © 2016年 Yuming. All rights reserved.
//

#import "CheckTextField.h"

@implementation CheckTextField

- (void)drawRect:(CGRect)rect {
    
    CGContextRef ctx = UIGraphicsGetCurrentContext();
    
    CGContextClearRect(ctx, rect);
    
    // 设置线条颜色
    
    CGContextSetRGBStrokeColor(ctx, 255.0f/256.0f, 207.0f/256.0f, 87.0f/256.0f, 1.0f);
    
    
    /** 绘制线是可以任意的顺序，按照宽和高来控制绘制 */
    CGContextMoveToPoint(ctx, 0, rect.size.height - 3);
    
    CGContextAddLineToPoint(ctx, rect.size.width, rect.size.height - 3);
    
    
//    
//    CGContextMoveToPoint(ctx, 1, rect.size.height - 10);
//    
//    CGContextAddLineToPoint(ctx, 1, rect.size.height - 2);
//    
//    
//    
//    CGContextMoveToPoint(ctx, rect.size.width - 1, rect.size.height - 10);
//    
//    CGContextAddLineToPoint(ctx, rect.size.width - 1, rect.size.height - 2);
    
    
    
    CGContextMoveToPoint(ctx, rect.size.width - 100 , 7);
    
    CGContextAddLineToPoint(ctx, rect.size.width - 100, rect.size.height - 7);
    
    
    
    // 开始绘图
    
    CGContextStrokePath(ctx);
    
}



/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/

@end
